/*	talmud - The TALMUD roguelike
 * Copyright (C) 2012, talmud contributors
 *
 *  This program is free software; you can redistribute it and/or modify it
 *  under the terms of Version 2 of the GNU General Public License as published
 *  by the Free Software Foundation.
 *
 *  This program is distributed in the hope that it will be useful, but WITHOUT
 *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 *  FITNESS FOR A PARTICULAR PURPOSE. See Version 2 of the GNU General Public
 *  License for more details.
 *
 *  You should have received a copy of the GNU General Public License along
 *  with this program; if not, write to the Free Software Foundation, Inc.,
 *  59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 */

#ifndef monster_h
#define monster_h

#include <stdint.h>

#define F_NONE		0x00
#define F_ASLEEP	0x01	// hasn't yet woken up from being generated asleep
#define F_SLEEPING	0x02	// asleep from magical effects
#define F_PEACEFUL	0x04

#define MON_BOSS	0

#define TURNSPEED	10

#define MONMAXINV	4

#define MONR2		100

#include "item.h"

typedef struct monster_s
{
	uint32_t cintrins;
	uint32_t resists;
	uint16_t flags;
	uint8_t race;
	uint16_t hp;
	uint8_t exhaustion;
	uint8_t x;
	uint8_t y;
	uint8_t dlvl;
	uint8_t branch;
	uint8_t speedcounter;
	uint8_t invcount;
	item_t inv[MONMAXINV];
} monster_t;

typedef struct player_s
{
	monster_t mon;
	uint8_t class;
	uint16_t maxhp;
	uint8_t xlvl;
	uint32_t xp;
	int8_t ac;
	uint8_t st;
	uint8_t dx;
	uint8_t co;
	uint8_t in;
	uint8_t wi;
	uint8_t ch;
	int8_t relig;
	int8_t luck;
	uint16_t invisturns;
	uint16_t infravisturns;
	uint16_t paralyzedturns;
	uint16_t sleepturns;
	uint16_t confturns;
} player_t;

#endif
